<template>
	<!-- 佣金 申请提现 -->
    <div class="brokerage-WithdrawDetails">
      <!-- 导航 -->
      <tz-breadcrumb  :pathArr='[{"name": "佣金"},{"name": "提现记录", "url": "/WithdrawList"},{"name": "提现记录详情", "url": "/WithdrawDetails"}]'></tz-breadcrumb>
              <!-- 数据表单 -->
<div style="margin: 20px;"></div>
<el-row :gutter="20">
  <el-col :span="12">
    <el-table :data="tableData" stripe style="width: 100%">
      <el-table-column prop="name" label="名称" ></el-table-column>
      <el-table-column prop="date" label="值" > </el-table-column>
    </el-table>
  </el-col>
  <el-col :span="12">
    <el-table :data="payDate" stripe style="width: 100%">
      <el-table-column prop="name" label="名称" ></el-table-column>
      <el-table-column prop="date" label="值" > </el-table-column>
    </el-table>
  </el-col>

  <!--<el-col :span="12">-->
    <!--<el-table :data="tableData" stripe style="width: 100%">-->
      <!--<el-table-column prop="date" label="名称" ></el-table-column>-->
      <!--<el-table-column prop="name" label="值" > </el-table-column>-->
    <!--</el-table>-->
  <!--</el-col>-->
</el-row>
    </div>
</template>

<script>
import tzBreadcrumb from './../../components/breadcrumb/breadcrumb.vue';
import api from './../../api/api';
import http from './../../config/index';
export default {
  components: {
    'tz-breadcrumb': tzBreadcrumb
  },
  data () {
    return {
      tableData: [],
      payDate: []
    };
  },
  created () {
    this.requestData();
  },
  methods: {
    requestData () {
      let that = this;
      console.log('aaa');
      http.post(api.WithdrawAccountDetail, {
        token: localStorage.getItem('token'),
        id: that.$route.query.id
      }, response => {
        let content = response.data[0].result;
        console.log(response.data[0].result);
        that.tableData.push({date: content.id, name: '提现编号'});
        that.tableData.push({date: content.uid, name: '提现用户编号'});
        that.tableData.push({date: content.pay_type, name: '提现类型'});
        that.tableData.push({date: content.withdraw_status, name: '提现状态'});
        that.tableData.push({date: content.username, name: '提现用户名'});
        that.tableData.push({date: content.pay_username, name: '收款账户人名'});
        that.tableData.push({date: content.process_uid, name: '受理人编号'});
        that.tableData.push({date: content.process_username, name: '受理人用户名'});
        that.tableData.push({date: content.withdraw_cash, name: '提现金额'});
        that.tableData.push({date: content.fee, name: '提现手续费'});
        that.tableData.push({date: content.pay_account, name: '提现账号'});
        that.tableData.push({date: content.remark, name: '备注'});
        that.tableData.push({date: content.applic_time, name: '申请时间'});
        that.tableData.push({date: content.process_time, name: '受理时间'});
        that.tableData.push({date: content.created_at, name: '创建时间'});
        that.tableData.push({date: content.updated_at, name: '更新时间'});
        if (content.order !== null) {
          that.payDate.push({date: content.order.partner_trade_no, name: '系统订单号'});
          that.payDate.push({date: content.order.payment_no, name: '支付订单号'});
          that.payDate.push({date: content.order.type, name: '订单类型'});
          that.payDate.push({date: content.order.fina_type, name: '进出类型'});
          that.payDate.push({date: content.order.payways, name: '所属支付通道'});
          that.payDate.push({date: content.order.pay_status, name: '系统订单状态'});
          that.payDate.push({date: content.order.status, name: '支付状态'});
          that.payDate.push({date: content.order.real_amount, name: '到账金额'});
          that.payDate.push({date: content.order.remark, name: '备注信息'});
          that.payDate.push({date: content.order.created_at, name: '创建时间'});
        }
      }, err => {
        console.log(err);
      });
    }
  }
};
</script>

<style lang="stylus" scoped>
.form
  padding: 2rem
  margin-top: 15px
  margin-bottom: 12px
  box-sizing: border-box
  background: #fff
  box-shadow: 1px 1px 1px #999
  .form-item
    display: inline-block
    margin-right: 35px
    label
      font-size: 14px
      color: #333
      width: 70px
      display: inline-block
    .form-input, .form-select
      width: 200px
  .line
    height: 15px
.server-item
  width: 20px
  height: 20px
  margin: 5px
  
</style>
